<?php
header("Content-type: application/octet-stream");
header("Content-Disposition: attachment; filename=RekapPV.xls");
header("Pragma: no-cache");
header("Expires: 0");

?>

<h3>LAPORAN PV</h3>
<div class="clr"></div>

<?php
	$width_tabel='100%'; // untuk ukuran tabel bila belum pilih kriteria
	$width_tabel='100%'; // untuk ukuran tabel bila sudah pilih kriteria
?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
<title>Untitled Document</title>
</head>
<body>
<table border="1" width="100%">
	<thead>
		<th>Nama Manager</th>
        <th>Nama Upline</th>
        <th>Unit</th>
		<th>Omset Unit</th>
		<th>PV Unit</th>
	</thead>
	<tbody>
		<?php 
			$no=0;
			foreach($default as  $d):
			$no++;
        ?>
     <tr class="detail">
       <td align="justify"><?php echo $d->strnama_dealer?></td>
       <td align="justify"><?php echo $d->strnama_upline?></td>
       <td align="justify"><?php echo $d->strnama_unit?></td>
       <td align="justify"><?php echo $d->inttotal_omset?></td>
       <td align="justify"><?php echo $d->intpv?></td>
      </tr>
      <?php endforeach;?>
	</tbody>
</table>
</body>
</html>
